package com.neu.cpsp.service.impl;

import com.neu.cpsp.dao.PerformanceHistoryMapper;
import com.neu.cpsp.pojo.PerformanceHistory;
import com.neu.cpsp.service.PerformanceHistoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @author neu.xiaojiacheng
 * @version 1.0
 * @date 2022/2/24 15:01
 */
@Service
@Transactional
public class PerformanceHistoryServiceImpl implements PerformanceHistoryService {
    @Autowired
    private PerformanceHistoryMapper performanceHistoryMapper;

    @Override
    public List<PerformanceHistory> selectPerformanceValue(Integer year, Integer quarter) {
        return performanceHistoryMapper.selectPerformanceValue(year, quarter);
    }

    @Override
    public List<PerformanceHistory> selectPerValueDepart(Integer year, Integer quarter, List<String> idCardList) {
        return performanceHistoryMapper.selectPerValueDepart(year, quarter, idCardList);
    }

    @Override
    public int insert(PerformanceHistory record) {
        return performanceHistoryMapper.insert(record);
    }

    @Override
    public int updateByPrimaryKeySelective(PerformanceHistory record) {
        return performanceHistoryMapper.updateByPrimaryKeySelective(record);
    }
}
